package china.school.advised;

import org.springframework.aop.support.StaticMethodMatcherPointcut;

import java.lang.reflect.Method;

// 自定义切入点
class MyPointcut extends StaticMethodMatcherPointcut {
	@Override
	public boolean matches(Method method, Class<?> targetClass) {
		// 只匹配 doAnotherThing 方法
		return "doAnotherThing".equals(method.getName());
	}
}
